package com.chuyu.cy.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.chuyu.cy.contants.PageResult;
import com.chuyu.cy.entity.domain.ChatMessage;
import com.chuyu.cy.entity.vo.MessageVO;

/**
* @author 周小白
* @description 针对表【chat_message】的数据库操作Service
*/
public interface ChatMessageService extends IService<ChatMessage> {


    /**
     * 获取聊天记录
     * @param userId the user
     * @param contactorId the contactor
     * @param pageNum the page number
     * @param pageSize the page size
     * @return the message list
     */
    PageResult<MessageVO> getMessageList(Integer userId, Integer contactorId, Integer pageNum, Integer pageSize);



    /**
     * 保存消息
     * @param messageVO the message
     * @return the result
     */
    MessageVO saveMessage(MessageVO messageVO);
}
